package com.lakeworks.common.exception.response;

import com.lakeworks.common.enums.ResponseEnum;
import lombok.Getter;

/**
 * @Author: Auxps
 * @Date: 2023/8/16
 * Description:
 *      用于前端提示的异常
 */
@Getter
public class ResponseException extends RuntimeException {

    private static final long serialVersionUID = 8287583393116805510L;

    private String message;

    public ResponseException(ResponseEnum responseEnum) {
        super(responseEnum.getMessage());
        this.message = responseEnum.getMessage();
    }

    public ResponseException(String message) {
        super(message);
        this.message = message;
    }
}
